package spi;

import java.util.ServiceLoader;

/**
 * Created by duan lian on 2018-02-24.
 */
public class ServiceLoaderDemo {
	public static void main(String[] args) {
		ServiceLoader<HelloService> services = ServiceLoader.load(HelloService.class);
		services.forEach(s->System.out.println(s.hello("www")));
	}
}

